<template>
  <div class="myHeader-box">
    <!-- 头部区域 -->
    <div class="header">
      <button @click="back">退出登录</button>
    </div>
  </div>
</template>

<script>
export default {
  methods: {
    back() {
      localStorage.removeItem('token');
      this.$router.push('/login');
    }
  }
};
</script>

<style lang="less" scoped>
.myHeader-box {
  padding: 0;
  margin: 0;
  width: 100%;
  min-height: 200px;
  background-color: rgb(104, 195, 231);
  .header {
    float: right;
  }
}
</style>